package netdemo;

import java.net.InetAddress;
import java.net.UnknownHostException;

public class InetAddressDemo {

    public static void main(String[] args) {
        try {
            InetAddress localHost = InetAddress.getLocalHost();
            System.out.println(localHost);
//            InetAddress byName = InetAddress.getByName("LAPTOP-84LD10EV");
        } catch (UnknownHostException e) {
            e.printStackTrace();
        }
    }
}
